﻿#ifndef DEVICEREGISTERCODEC_UNREGISTER_H
#define DEVICEREGISTERCODEC_UNREGISTER_H

#include "qobject.h"
#include "ObjAutoInject.h"
#include "DeviceRegisterCodecBase.h"

#include "LogSaver.h"

class DataPackage_UdpCodec;
class RegisterCenter_Device;
class DeviceRegisterCodec_Unregister : public QObject,public ObjAutoInject,public DeviceRegisterCodecBase
{
  Q_OBJECT
private://dependency
  RegisterCenter_Device* registerCenter_Device=Q_NULLPTR;
  LogSaver* logSaver=LogSaver::getLogSaver();
public:
  explicit DeviceRegisterCodec_Unregister();
  virtual ~DeviceRegisterCodec_Unregister();
public:
  virtual DataPackage_UdpCodec* decode(DataPackage_UdpCodec* dataPackageInfo_Device)override;
public://geter and seter
  RegisterCenter_Device* getRegisterCenter_Device() const;
  DeviceRegisterCodec_Unregister* setRegisterCenter_Device(RegisterCenter_Device* const registerCenter_Device);
public:
  virtual void objectAutoInjection(QHash<QString,QObject*>* objMap)override;
};

#endif // DEVICEREGISTERCODEC_UNREGISTER_H
